package com.zfz.power.verify;

import com.zfz.power.common.User;

/**
 * @Description:
 * @Author: zhoufuzong
 * @Created: 2020-12-05 18:48:30
 * @Version: 1.1.0
 */

public class UserService {

    public void saveOrUpdate(User user){
        UserDao userDao = new UserDao();

        if (userDao.getCount(user)>0){
            userDao.updateUser(user);
        }else {
            userDao.insertUser(user);
        }
    }
}
